package mx.com.erl.billar.controller;

import java.util.List;
import mx.com.erl.billar.service.InventarioService;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.servlet.ModelAndView;

@Controller
@RequestMapping("billar")
public class GenerarInventarioController {

	@Autowired
	private InventarioService inventarioService;
	
	@RequestMapping()
	public String goHola(){
		return "cliente/venta";
	}
	@RequestMapping(value="generarInventario",method=RequestMethod.POST)
	public ModelAndView AltaUsuario(){
		
		System.out.println("en la consulta para Inventario");
		return new ModelAndView("cliente/inventario","inventario",inventarioService.consultaInventario());
	}

}
